<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:ui="http://java.sun.com/jsf/facelets"
      xmlns:h="http://java.sun.com/jsf/html"
      xmlns:p="http://primefaces.org/ui"
      xmlns:f="http://java.sun.com/jsf/core" xml:lang="en" lang="en">
    <head>
        <title>My Facelets Page</title>
        <meta http-equiv="keywords" content="enter,your,keywords,here" />
        <meta http-equiv="description"
              content="A short description of this page." />
        <meta http-equiv="content-type" content="text/html; charset=UTF-8" />

        <!--<link rel="stylesheet" type="text/css" href="styles.css">-->
    </head>
    <body>
        <ui:composition template="BackGeneral.xhtml">
            <ui:define name="content">
                <h:form id="form1">
                    <h:outputText id="outputText1" styleClass="tit"
                                  value="－查看/修改用户－" />
                    <p:growl id="msg"/>
                    <p:separator style="margin:5px 0px 10px 0px" />
                    <h:panelGrid columns="2" style="">
                        <h:outputLabel styleClass="text" value="用户名：" />
                        <h:outputText value="#{viewClientUser.cu.username}"></h:outputText>
                        <h:outputLabel styleClass="text" value="初始化密码：" />
                        <h:panelGroup>
                            <p:commandButton value="初始化" action="#{viewClientUser.initPwd}" update=":form1:msg"></p:commandButton>
                            <h:outputLabel styleClass="text" value="初始化密码为：#{applicationBean.systemConfig.initPwd}" />
                        </h:panelGroup>

                        <h:outputLabel styleClass="text" value="姓名：" />
                        <h:inputText value="#{viewClientUser.cu.name}"></h:inputText>
                        <h:outputLabel styleClass="text" value="电话：" />
                        <h:inputText value="#{viewClientUser.cu.tel}"></h:inputText>
                        <h:outputLabel styleClass="text" value="E-MAIL：" />
                        <h:inputText value="#{viewClientUser.cu.email}"></h:inputText>
                        <h:outputLabel styleClass="text" value="空间分配：" />
                        <h:panelGroup>
                            <h:inputText value="#{viewClientUser.cu.totalLength}"></h:inputText>MB
                        </h:panelGroup>
                        <h:outputLabel styleClass="text" value="用户积分：" />
                        <h:panelGroup>
                            <h:inputText value="#{viewClientUser.cu.score}"></h:inputText>
                        </h:panelGroup>

                        <h:outputLabel styleClass="text" value="注册日期：" />
                        <h:outputText value="#{viewClientUser.cu.regTime}">
                            <f:convertDateTime pattern="yyyy-MM-dd HH:mm:ss" timeZone="GMT+8" />
                        </h:outputText>
                    </h:panelGrid>
                    <p:separator/>
                    <p:commandButton action="#{viewClientUser.finish}" value="提交" ajax="false"></p:commandButton>
                </h:form>
            </ui:define>
        </ui:composition>
    </body>
</html>
